<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>大麦搜索</title>


    <link rel="stylesheet" href="../../static/css/webdamai.css" th:href="@{/css/webdamai.css}">


</head>


<body>

<!--页头开始====================================================-->
<div class="header">
    <!--头部导航开始-->
    <div class="header-wrap">
        <div class="header-box">
            <a href="#" class="header-box-left clearfix left">
                <img src="../../static/img/front/dm-log1.png" th:src="@{/img/front/dm-log1.png}"/>
            </a>

            <div class="header-recommend">
                <a href="" class="type-recommend ">首页</a>
                <a href="" class="type-recommend select">分类</a>
            </div>
            <div class="header-right">
                <div class="header-right-search">
                    <img src="../../static/img/front/TB1qv3jxGmWBuNjy1XaXXXCbXXa-34-36.png"
                         th:src="@{/img/front/TB1qv3jxGmWBuNjy1XaXXXCbXXa-34-36.png}" alt="" class="i-search">
                    <input type="text" class="input-search" placeholder="搜索明星、演出、体育赛事">
                    <div class="btn-search">搜索</div>
                </div>
                <div class="header-right-option right clearfix">
                    <a href="" class="to-login box-header left clearfix">
                        <img class="i-box-header" src="../../static/img/front/TB14UKCGQyWBuNjy0FpXXassXXa-54-54.png"
                             th:src="@{/img/front/TB14UKCGQyWBuNjy0FpXXassXXa-54-54.png}" alt="">
                        <span class="span-box-header">登录</span>
                        <div class="list-login">
                            <span href="#" class="li-login">个人信息</span>
                            <span href="#" class="li-login">账号设置</span>
                            <span href="#" class="li-login">订单管理</span>

                        </div>
                    </a>
                    <div class="app-QRCode box-header left">
                        <img class="i-box-header" src="../../static/img/front/TB1A9eIGKuSBuNjy1XcXXcYjFXa-54-54.png"
                             th:src="@{/img/front/TB1A9eIGKuSBuNjy1XcXXcYjFXa-54-54.png}" alt="">
                        <span class="span-box-header">下载</span>
                        <div class="list-QRCode">
                            <img src="../../static/img/front/TB1r0uFxHSYBuNjSspiXXXNzpXa-280-280.png"
                                 th:src="@{/img/front/TB1r0uFxHSYBuNjSspiXXXNzpXa-280-280.png}" alt=""
                                 class="li-QRCode">
                        </div>
                    </div>
                    <a href="" class="language box-header left">
                        <img class="i-box-header" src="../../static/img/front/TB13UKCGQyWBuNjy0FpXXassXXa-54-54.png"
                             th:src="@{/img/front/TB13UKCGQyWBuNjy0FpXXassXXa-54-54.png}" alt="">
                        <span class="span-box-header">English</span>
                    </a>
                </div>
            </div>

        </div>
    </div>
    <!--头部导航结束-->
</div>
<!--页头结束====================================================-->


<!-- 业头右侧-->

<!--已 recommend 主体开始-->

<div class="recommend-works clearfix ">
    <div class="recommend-works-daohang">
        你还可能喜欢
    </div>
    <div class="recommend-works-logo">
        <div class="recommend-works-logo1">
            <img src="../../static/img/front/168279_n.jpg" th:src="@{/img/front/168279_n.jpg}" alt="">
            <a class="recommend-works-a" href="#">
                【预售特惠】 <br>
                BIGBANG10 THE <br>
                EXHIBITON:A TO...
            </a>
            <span> 798艺术中心 2018.12.07-2019.02...
            </span>
            <b style="color: #ed0a75">100.0元<span>&nbsp&nbsp起</span></b>
        </div>
        <div class="recommend-works-logo1">
            <img src="../../static/img/front/168279_n.jpg" th:src="@{/img/front/168279_n.jpg}" alt="">
            <a class="recommend-works-a" href="#">
                【预售特惠】 <br>
                BIGBANG10 THE <br>
                EXHIBITON:A TO...
            </a>
            <span> 798艺术中心 2018.12.07-2019.02...
            </span>
            <b style="color: #ed0a75">100.0元<span>&nbsp&nbsp起</span></b>
        </div>
        <div class="recommend-works-logo1">
            <img src="../../static/img/front/168279_n.jpg" th:src="@{/img/front/168279_n.jpg}" alt="">
            <a class="recommend-works-a" href="#">
                【预售特惠】 <br>
                BIGBANG10 THE <br>
                EXHIBITON:A TO...
            </a>
            <span> 798艺术中心 2018.12.07-2019.02...
            </span>
            <b style="color: #ed0a75">100.0元<span>&nbsp&nbsp起</span></b>
        </div>
    </div>
</div>


<!--主体开始====================================================-->
<div class="city clearfix">
    <!--city方法头部导航开始-->

    <div>共<span style="color:red">3950</span>个商品
    </div>
    <!--城市分类-->
    <div class="city-top clearfix">
        <div class="city-tp clearfix">
            <div class="city-tp1">

                <!--span通用-->
                <span class="city-biaoti">城&nbsp&nbsp&nbsp市:</span>
                <a class="city-quanbu" href="javascript:void (0)" data-for="queryCity" currentCity="y" th:value="0">全部</a>
                <div class="city-dizhi clearfix">
                    <a data-for="queryCity" class="city-hover" href="javascript:void (0)"
                       th:each="obj,objStat:${dmAreas}" th:text="${obj.name}" th:value="${obj.id}"
                       th:if="${objStat.index} < 10"></a>

                    <div class="city-hh clearfix">
                        <a data-for="queryCity" href="javascript:void (0)" th:each="obj,objStat:${dmAreas}"
                           th:text="${obj.name}" th:value="${obj.id}"
                           th:if="${objStat.index} >= 10 and ${objStat.index} < 20"></a>
                    </div>
                    <div class="city-gd clearfix">
                        <a href="#">更多∨</a>
                    </div>


                    <div class="city-overflow clearfix">
                        <a data-for="queryCity" href="javascript:void (0)" th:each="obj,objStat:${dmAreas}"
                           th:text="${obj.name}" th:value="${obj.id}"
                           th:if="${objStat.index} >= 20 and ${objStat.index} < 30"></a>
                    </div>
                    <div class="city-overflow clearfix">
                        <a data-for="queryCity" href="javascript:void (0)" th:each="obj,objStat:${dmAreas}"
                           th:text="${obj.name}" th:value="${obj.id}"
                           th:if="${objStat.index} >= 30 and ${objStat.index} < 40"></a>

                    </div>

                    <div class="city-overflow clearfix">
                        <a data-for="queryCity" href="javascript:void (0)" th:each="obj,objStat:${dmAreas}"
                           th:text="${obj.name}" th:value="${obj.id}"
                           th:if="${objStat.index} >= 40 and ${objStat.index} < 50"></a>
                    </div>

                    <div class="city-overflow clearfix">
                        <a data-for="queryCity" href="javascript:void (0)" th:each="obj,objStat:${dmAreas}"
                           th:text="${obj.name}" th:value="${obj.id}"
                           th:if="${objStat.index} >= 50 and ${objStat.index} < 60"></a>
                    </div>
                </div>
            </div>

            <!--city方法尾部结束-->


            <!--分类区域 sort方法头部导航开始-->
            <div class="sort-top">
                <span class="city-biaoti">分&nbsp&nbsp&nbsp类:</span>
                <a class="city-quanbu" href="javascript:void (0)" currentItemType="y" th:value="0">全部</a>
                <div class="sort-content   clearfix">
                    <a class="sort-hover" href="javascript:void (0)" th:each="obj,objStat:${dmItems}"
                       th:text="${obj.itemType}" th:value="${obj.id}" th:if="${objStat.index} < 8"></a>

                    <div class="sort-hh">
                        <a class="sort-hover" href="javascript:void (0)" th:each="obj,objStat:${dmItems}"
                           th:text="${obj.itemType}" th:value="${obj.id}"
                           th:if="${objStat.index} >=8  and ${objStat.index} < 12"></a>
                    </div>
                </div>
            </div>
            <!--sort方法尾部结束-->

            <!--&lt;!&ndash;子类分类区 subclass方法头部导航开始&ndash;&gt;-->
            <!--<div class="subclass-top">-->
            <!--&lt;!&ndash;span通用&ndash;&gt;-->
            <!--<span class="city-biaoti">子&nbsp&nbsp&nbsp类:</span>-->
            <!--<span class="city-quanbu">全部</span>-->
            <!--<div class="subclass-content clearfix">-->
            <!--<a class="subclass-hover" href="#">儿童剧</a>-->
            <!--<a class="subclass-hover" href="#">歌剧</a>-->
            <!--<a class="subclass-hover" href="#">歌舞剧</a>-->
            <!--<a class="subclass-hover" href="#">话剧</a>-->
            <!--<a class="subclass-hover" href="#">音乐剧</a>-->
            <!--</div>-->
            <!--</div>-->
            <!--subclass方法尾部结束-->

            <!--时间分类区  time方法头部导航开始-->
            <div class=" time-top">
                <!--span通用-->
                <span class="city-biaoti">时&nbsp&nbsp&nbsp间:</span>
                <a class="city-quanbu">全部</a>
                <div class=" time-content clearfix">
                    <a class="time-hover" href="#">今天</a>
                    <a class="time-hover" href="#">明天</a>
                    <a class="time-hover" href="#">本周末</a>
                    <a class="time-hover" href="#">一个月</a>
                    <a href="#"> <span>按时间段:</span>
                        <input type="date">-<input type="date">
                        <a class="time-hover-color" href="#"><img src="../../static/img/centre/33333.png"
                                                                  th:src="@{/img/centre/33333.png}" alt="">按日历</a></a>
                </div>
            </div>
            <!--subclass方法尾部结束-->
        </div>
    </div>
</div>

<!--已city开头，已subclass方法尾部结束-->


<!--已 search 方法头部导航开始-->
<div class="search_main clearfix">
    <div class="search-biaoti-top clearfix">
        <div class="search-biaoti">
            <a href="#">相关度排序</a>
        </div>
        <div class="search-biaoti1">
            <a href="#">推荐排序</a>
        </div>
        <div class="search-biaoti2">
            <a href="#">最近开场</a>
        </div>
        <div class="search-biaoti3">
            <a href="#">最新上架</a>
        </div>
        <div class="search-biaoti-img" data-for="top-page">
            <a class="search-biaoti-img1" href="#"> &nbsp>&nbsp </a>
            <a class="search-biaoti-img2" href="#">&nbsp &nbsp1/64&nbsp &nbsp</a>
            <a class="search-biaoti-img1" href="#"> &nbsp<&nbsp</a>
        </div>
        <div class="search-biaoti-img">
            <a class="search-biaoti-img3" href="#"><img src="../../static/img/centre/66666.png"
                                                        th:src="@{/img/centre/66666.png}" alt=""></a>
        </div>
        <div class="search-biaoti-img">
            <a class="search-biaoti-img3" href="#"><img src="../../static/img/centre/666669.png"
                                                        th:src="@{/img/centre/666669.png}" alt=""></a>
        </div>
    </div>
    <div class="search-logo-top" id="catalogue">
        <div class="search-logo">
            <img class="search-img" src="../../static/img/centre/dsds.jpg" th:src="@{/img/centre/dsds.jpg}" alt="">
            <span>【上海】</span>
            <a href="#">第六届上海音乐学院中提琴艺术节“我为中提狂”</a>
            <span class="search-txt">第六届上海音乐学院中提琴艺术节“我为中提狂”</span>
            <span class="search-data"><img src="../../static/img/centre/33333.png" th:src="@{/img/centre/33333.png}"
                                           alt="">2018.11.12 19:30</span>
            <span class="search-location"><img src="../../static/img/centre/6666.png" th:src="@{/img/centre/6666.png}"
                                               alt="">
                     凯迪拉克·上海音乐厅大厅 - 上海</span>
            <span class="search-price"><b style="color:#ed0a75;">80-180元</b> &nbsp&nbsp&nbsp售票中</span>
        </div>
        <div class="search-logo">
            <img class="search-img" src="../../static/img/centre/dsds.jpg" th:src="@{/img/centre/dsds.jpg}" alt="">
            <span>【上海】</span>
            <a href="#">第六届上海音乐学院中提琴艺术节“我为中提狂”</a>
            <span class="search-txt">第六届上海音乐学院中提琴艺术节“我为中提狂”</span>
            <span class="search-data"><img src="../../static/img/centre/33333.png" th:src="@{/img/centre/33333.png}"
                                           alt="">2018.11.12 19:30</span>
            <span class="search-location"><img src="../../static/img/centre/6666.png" th:src="@{/img/centre/6666.png}"
                                               alt="">凯迪拉克·上海音乐厅大厅 - 上海</span>
            <span class="search-price"><b style="color:#ed0a75;">80-180元</b> &nbsp&nbsp&nbsp售票中</span>
        </div>
        <div class="search-tail"  data-for="search-sort">

            <!--<a class="search-tail-text" href="#"><input type="text" value="<上一页" style="text-align: center"></a>-->
            <!--<a href="#"><input class="" type="text" value="1" style="text-align: center"></a>-->
            <!--&lt;!&ndash;<a href="#"><input type="text" value="2"  style="text-align: center"  ></a>&ndash;&gt;-->
            <!--&lt;!&ndash;<a href="#"><input type="text" value="3"  style="text-align: center"  ></a>&ndash;&gt;-->
            <!--&lt;!&ndash;<a href="#"><input type="text" value="4"  style="text-align: center"  ></a>&ndash;&gt;-->
            <!--&lt;!&ndash;<a href="#"><input type="text" value="5"  style="text-align: center"  ></a>&ndash;&gt;-->
            <!--<span>...</span>-->
            <!--<a class="search-tail-weibu" href="#"><input type="text" value="64" style="text-align: center"></a>-->
            <!--<a class="search-tail-text" href="#"><input type="text" value="下一页>" style="text-align: center"></a>-->
        </div>
    </div>
</div>
</div>
</div>
</div>

<!--已 search 方法尾部结束-->

<!--已 search 方法尾部结束-->


<!--页脚开始====================================================-->
<div class="footer">
    <div class="inner-footer">
        <ul class="footer__links">

            <li class="footer__links__list"><a href="//help.damai.cn?spm=a2oeg.home.0.0.591b48d3vh7j6x" target="_blank"
                                               data-spm="flink0" data-spm-anchor-id="a2oeg.home.0.0">帮助中心</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a href="//help.damai.cn/helpPage.htm?pageId=69&amp;categoryId=30"
                                               target="_blank" data-spm="flink1">公司介绍</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a href="//help.damai.cn/helpPage.htm?pageId=70&amp;categoryId=30"
                                               target="_blank" data-spm="flink2">品牌识别</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a href="//help.damai.cn/helpPage.htm?pageId=72&amp;categoryId=30"
                                               target="_blank" data-spm="flink3">公司大事记</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a href="//help.damai.cn/helpPage.htm?pageId=40&amp;categoryId=14"
                                               target="_blank" data-spm="flink4">隐私权专项政策</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a
                    href="//jubao.alibaba.com/internet/readme.htm?spm=a2o6e.search.0.0.72f44d15Votov6&amp;site=damai"
                    target="_blank" data-spm="flink5">廉正举报</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a href="//help.damai.cn/helpPage.htm?pageId=58&amp;categoryId=5"
                                               target="_blank" data-spm="flink6">联系合作</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a
                    href="//job.alibaba.com/zhaopin/positionList.htm?keyWord=JXU1OTI3JXU5RUE2&amp;_input_charset=UTF-8"
                    target="_blank" data-spm="flink7">招聘信息</a></li>
            <li class="footer__links__grep">|</li>

            <li class="footer__links__list"><a
                    href="//x.damai.cn/markets/special/fangzhapian?spm=a2o6e.home.0.0.75df48d3hqGWGD&amp;wh_ttid=pc"
                    target="_blank" data-spm="flink8">防骗秘籍</a></li>


        </ul>
        <div class="footer__ft clearfix">
            <div class="footer__ft_fl">
                <a href="" target="_blank" class="footer__ft__logo">
                    <img src="../../static/img/ending/dm-logo.png" th:src="@{/img/ending/dm-logo.png}" alt="">
                </a>
                <div class="footer__ft__code__box">
                    <img class="footer__ft__code" src="../../static/img/ending/TB1r0uFxHSYBuNjSspiXXXNzpXa-280-280.png"
                         th:src="@{/img/ending/TB1r0uFxHSYBuNjSspiXXXNzpXa-280-280.png}" alt="">

                    <span>APP下载</span>
                </div>
            </div>
            <div class="footer__ft_fr">
                <div class="footer__fr__contact clearfix">
                    <a style="margin-left:0;" href="" class="footer__fr__contact__btn alime">在线客服</a>
                </div>
                <ul class="footer__ft__words clearfix">
                    <li class="footer__ft__certificate"><a
                            href="http://www.miitbeian.gov.cn?spm=a2o6e.home.0.0.5b4d48d3mVzb2Z" target="_blank"
                            class="colorPink">京ICP证031057号</a></li>
                    <li class="footer__ft__grep">|</li>
                    <li class="footer__ft__certificate"><a href="http://www.miitbeian.gov.cn" target="_blank"
                                                           class="colorPink">京ICP备11043884号</a></li>
                    <li class="footer__ft__grep">|</li>
                    <li class="footer__ft__certificate"><a
                            href="http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=11010102000430"
                            target="_blank" class="colorPink">京公网安备11010102000430号</a>
                    </li>
                    <li class="footer__ft__grep">|</li>
                    <li class="footer__ft__certificate"><a
                            href="//img.alicdn.com/tfs/TB1K9r6xN9YBuNjy0FfXXXIsVXa-1152-799.jpg" target="_blank"
                            class="colorPink">广播电视节目制作经营许可证
                        (京)字第02253号</a></li>
                </ul>
                <ul class="footer__ft__words clearfix">
                    <li class="footer__ft__certificate"><a
                            href="//img.alicdn.com/tfs/TB1AsH4xH9YBuNjy0FgXXcxcXXa-1420-1032.jpg" target="_blank"
                            class="colorPink">网络文化经营许可证
                        京网文[2016]3438-413号</a></li>
                    <li class="footer__ft__grep">|</li>
                    <li class="footer__ft__certificate"><a
                            href="//img.alicdn.com/tfs/TB1DfD6CxGYBuNjy0FnXXX5lpXa-1079-1527.jpg" target="_blank"
                            class="colorPink">营业性演出许可证
                        京市演587号</a></li>
                </ul>
                <ul class="footer__ft__words clearfix">
                    <li class="footer__ft__certificate">北京红马传媒文化发展有限公司 版权所有</li>
                    <li class="footer__ft__certificate"><a
                            href="//www.damai.cn/?spm=a2o6e.home.0.0.591b48d3QzpG8B">大麦网</a></li>
                    <li>Copyright 2003-2018 All Rights Reserved</li>
                </ul>
                <div class="footer__ft__img">
                    <span id="siteseal">

                    <img style="cursor:pointer;cursor:hand" class="footer__ft__img1"
                         src="//img.alicdn.com/tfs/TB1gw_ZxNWYBuNjy1zkXXXGGpXa-131-32.gif" onclick="verifySeal();"
                         alt="SSL site seal - click to verify" data-spm-anchor-id="a2o6e.home.0.i1.5b4d48d3mVzb2Z">
                    </span>
                    <a rel="nofollow" title="电子营业执照" target="_blank"
                       href="//img.alicdn.com/tfs/TB16oonxSBYBeNjy0FeXXbnmFXa-555-825.jpg">
                        <img class="footer__ft__img2" alt=""
                             src="../../static/img/ending/TB1ZO80pyOYBuNjSsD4XXbSkFXa-141-41.png"
                             th:src="@{/img/ending/TB1ZO80pyOYBuNjSsD4XXbSkFXa-141-41.png}">

                    </a>

                    <a rel="nofollow" target="_blank" href="https://www.pcisecuritystandards.org/">
                        <img src="../../static/img/ending/TB1Y580pyOYBuNjSsD4XXbSkFXa-83-50.png"
                             th:src="@{/img/ending/TB1Y580pyOYBuNjSsD4XXbSkFXa-83-50.png}" class="footer__ft__img3">

                    </a>
                    <a rel="nofollow" target="_blank"
                       href="http://www.itrust.org.cn/home/index/itrust_certifi/wm/1756737221">
                        <img src="../../static/img/ending/TB1pM_ZxNWYBuNjy1zkXXXGGpXa-114-40.png"
                             th:src="@{/img/ending/TB1pM_ZxNWYBuNjy1zkXXXGGpXa-114-40.png}" class="footer__ft__img4w">

                    </a>
                    <a target="_blank" href="https://search.szfw.org/cert/l/CX20130327002367002885"
                       id="___szfw_logo___">
                        <img class="footer__ft__img4"
                             src="../../static/img/ending/TB1C4nNxTlYBeNjSszcXXbwhFXa-114-42.png"
                             th:src="@{/img/ending/TB1C4nNxTlYBeNjSszcXXbwhFXa-114-42.png}">

                    </a>
                </div>
            </div>
        </div>
    </div>
</div>
<!--页脚结束====================================================-->


<!--固定窗口开始==================================================-->
<div class="fixeds">
    <div class="inner-fixeds">
        <a href="" class="box-inner-fixeds colorPink">
            <div class="icon-box-inner-fixeds service"></div>
            <p>在线客服</p>
        </a>
    </div>
    <div class="inner-fixeds damai-inner-fixeds">
        <a href="" class="box-inner-fixeds colorPink">
            <div class="icon-box-inner-fixeds damai"></div>
            <p>APP下载</p>
            <div class="qrcode-box-inner-fixeds">
                <img src="../../static/img/fixeds/TB1r0uFxHSYBuNjSspiXXXNzpXa-280-280.png"
                     th:src="@{/img/fixeds/TB1r0uFxHSYBuNjSspiXXXNzpXa-280-280.png}" width="72" height="72">

            </div>
        </a>
    </div>
    <div class="last-inner-fixeds">
        <a href="" class="box-inner-fixeds colorPink">
            <div class="icon-box-inner-fixeds gotop"></div>
            <p>回到顶部</p>
        </a>
    </div>

</div>
<!--固定窗口结束==================================================-->

<script src="../static/js/jquery.js" th:src="@{/js/jquery.js}"></script>

<script>
    $(function () {
        var count = 0;

        $(".city-gd").click(function () {
            if ((count % 2) == 0) {
                $(".city-dizhi").css("overflow", "fragments").css("height", "auto");
                $(".city-gd a").html("收起∧");
                count++;
            } else {
                $(".city-dizhi").css("overflow", "hidden").css("height", "62px");
                $(".city-gd a").html("更多∨");
                count++;
            }

        })


        //    回到顶部按钮出现，，，先获得滚动条垂直坐标
        //     加载完成，先判断垂直位置，让是否显示回到顶部按钮
        var y = $(document).scrollTop();
        if (y > 150) {
            $('.last-inner-fixeds').css('display', 'block');
        } else {
            $('.last-inner-fixeds').css('display', 'none');
        }
        //    滚动事件获取
        $(window).scroll(function () {
            //    获得垂直位置
            var y = $(document).scrollTop();
            if (y > 150) {
                $('.last-inner-fixeds').css('display', 'block');
            } else {
                $('.last-inner-fixeds').css('display', 'none');
            }
        });
        // 通过按钮回到顶部，触发自动回到顶部
        $('.last-inner-fixeds').click(function () {
            $('html,body').animate({scrollTop: 0}, 300);
        })

        //相关度排序
        $('.search-biaoti').click(function () {
            $.ajax({
                url: '/sort/list/page/8/1/1',
                type: 'get',
                success: function (data) {
                    renderTable(data.list);
                    renderPage(data);
                }
            })
        })

        //推荐排序
        $('.search-biaoti1').click(function () {
            $.ajax({
                url: '/sort/list/page/8/1/2',
                type: 'get',
                success: function (data) {
                    renderTable(data.list);
                    renderPage(data);
                }
            })
        })
        //最近开场


        $('.search-biaoti2').click(function () {
            $.ajax({
                url: '/sort/list/page/8/1/3',
                type: 'get',
                success: function (data) {
                    renderTable(data.list);
                    renderPage(data);
                }
            })
        })

        //最新上架
        $('.search-biaoti3').click(function () {
            $.ajax({
                url: '/sort/list/page/8/1/4',
                type: 'get',
                success: function (data) {
                    renderTable(data.list);
                    renderPage(data);
                }
            })
        })

    })


    $(function () {

        // // 获取文档分类信息
        // $.ajax({
        //     url:'/category/get/all',
        //     type:'get',
        //     success:function (data) {
        //         //
        //         var html = '<option value="0">-全部-</option>';
        //         for(var i  = 0 ; i < data.length; i ++){
        //             html += '<option value="'+data[i].id+'">'+data[i].name+'</option>'
        //         }
        //         $('#category').empty().html(html);
        //     }
        // })


        //点击城市查询节目
        $("a[data-for=queryCity]").click(function () {
            //获得当前城市，删除标记
            $("a[currentCity=y]").removeAttr("currentCity");
            //对点击城市进行标记
            $(this).attr("currentCity", "y");
            //获得点击城市的id
            var areaId = $(this).attr("value");
            //获得当前分类的id
            var itemTypeId = $("a[currentItemType=y]").attr("value");
            $.ajax({
                url: '/sort/list/page/8/1/' + areaId + '/' + itemTypeId,
                type: 'get',
                success: function (data) {
                    // page 对象
                    renderTable(data.list);
                    renderPage(data)

                }
            })
        })

    })

        // // 获取所有文档信息，带分页
        // $.ajax({
        //     url:'search/list/page/8/1',
        //     type:'get',
        //     success:function (data) {
        //         // page 对象
        //         renderTable(data.list);
        //
        //     }
        // })

        //     // 相关排序
        //     $('#queryBtn').click(function () {
        //         // 获取id
        //         var categoryId = $('select').val();
        //         $.ajax({
        //             url:'entry/list/page/3/1?categoryId='+categoryId,
        //             type:'get',
        //             success:function (data) {
        //                 // page 对象
        //                 renderTable(data.list);
        //
        //
        //             }
        //         })
        //
        //     })
        // })


        function renderTable(list) {
            var html = '';
            for (var i = 0; i < list.length; i++) {
                html += ' <div class="search-logo">\n' +
                    '                <img class="search-img" src="/img/centre/dsds.jpg" alt="">\n' +
                    '                <span>【' + list[i].dmCinema.areaName + '】</span>\n' +
                    '                <a href="#">' + list[i].itemName + '</a>\n' +
                    '                <span class="search-txt">' + list[i].abstractMessage + '</span>\n' +
                    '                <span class="search-data"><img src="/img/centre/33333.png" alt="">'+ list[i].startTime+' - '+ list[i].endTime+'</span>\n' +
                    '                <span class="search-location"><img src="/img/centre/6666.png" alt="">' + list[i].itemName + '</span>\n' +
                    '                <span class="search-price"><b style="color:#ed0a75;">' + list[i].minPrice + '-' + list[i].maxPrice + '元</b> &nbsp&nbsp&nbsp售票中</span>\n' +
                    '            </div>';
            }
            $('#catalogue').empty().html(html);
        }

        function renderPage(page) {
            var pages = page.pages;
            var currPage = page.pageNum;

            alert(121);

            //绑定上面mm5分页数渲染数据
            var htmlNum = '';
            htmlNum += '<a href="javascript:void(0)" class="search-biaoti-img1" page="' + page.nextPage + '"> &nbsp >  &nbsp</a>';
            htmlNum += '<span class="search-biaoti-img2"> &nbsp &nbsp' + currPage + '/' + pages +' &nbsp &nbsp</span>';
            htmlNum += '<a href="javascript:void(0)" class="search-biaoti-img1" page="' + page.prePage + '"> &nbsp < &nbsp</a>';

            //绑定下面分页数据
            var html = '';
            html += '<div class="search-tail"  data-for="search-sort">';
            html += '<a class="search-tail-text" href="javascript:void(0)" page="' + page.prePage + '">上一页</a>';
            if (pages > 7) {
                if (currPage >= 6) {
                    html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (1) + '">' + (1) + '</a>';
                    html += '<a class="search-tail-dian">...</a>';

                    if (currPage <= (pages - 5)) {
                        html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (currPage - 1) + '">' + (currPage - 1) + '</a>';
                        html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (currPage) + '" style="border: 1px solid red">' + (currPage) + '</a>';
                        html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (currPage + 1) + '">' + (currPage + 1) + '</a>';
                    }

                    if (currPage >= (pages - 4)) {
                        //临界点
                        for (var i = 5; i >= 0; i--) {
                            if ((pages - i) == currPage) {
                                html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (pages - i) + '" style="border: 1px solid red">' + (pages - i) + '</a>';
                            } else {
                                html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (pages - i) + '">' + (pages - i) + '</a>';
                            }
                        }

                    } else {
                        //当前页前后
                        html += '<a class="search-tail-dian">...</a>';
                        html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (pages) + '">' + (pages) + '</a>';

                    }
                    html += '<a class="search-tail-text" href="javascript:void(0)" page="' + (currPage + 1) + '">下一页</a>';
                } else {
                    for (var i = 0; i < 6; i++) {
                        if ((i + 1) == currPage) {
                            html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (i + 1) + '" style="border: 1px solid red">' + (i + 1) + '</a>';
                        } else {
                            html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (i + 1) + '">' + (i + 1) + '</a>';
                        }
                    }
                    html += '<a class="search-tail-dian">...</a>';
                    html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (pages) + '">' + (pages) + '</a>';
                    html += '<a class="search-tail-text" href="javascript:void(0)" page="' + page.nextPage + '">下一页</a>';
                }
            } else {
                //小于7条数据全部展示
                for (var i = 0; i < pages; i++) {
                    if ((i + 1) == currPage) {
                        html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (i + 1) + '" style="border: 1px solid red">' + (i + 1) + '</a>';
                    } else {
                        html += '<a class="search-tail-ye" href="javascript:void(0)" page="' + (i + 1) + '">' + (i + 1) + '</a>';
                    }
                }
            }
            html += '</div>';
            alert(html);
            $('div[data-for=top-page]').empty().html(htmlNum);
            $('#catalogue').append(html);

            //绑定页数
            $('a[page]').click(function () {
                var pageNum = $(this).attr('page');
                var areaId = $('a[currentCity=y]').attr("value");
                var itemTypeId = $("a[currentItemType=y]").attr("value");
                // $(this).css("border","1px solid red");
                if (pageNum > pages) {
                    return;
                } else {
                    //重新获取信息
                    $.ajax({
                        url: '/sort/list/page/8/' + pageNum + '/' + areaId + '/' + itemTypeId,
                        type: 'get',
                        success: function (data) {
                            renderTable(data.list);
                            renderPage(data);
                        }
                    })
                }
            })
        }


</script>
</body>
</html>